import createDOMElement from './createDOMElement'

export default function mountNativeElement (virtualDOM, container) {
    let newElement = createDOMElement(virtualDOM)
    // 将转换后的 dom 对象 放置在页面中
    container.appendChild(newElement)
    // 获取组件实例对象保存dom
    let component =  virtualDOM.component

    component && component.setDOM(newElement)
}